/*! ******************************************************************************
 *
 * Created on 2022年3月6日
 *
 * Copyright(c) YuZhou Big Data Laboratory CO.,Ltd, 2022.  All rights reserved.
 *
 *******************************************************************************
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with
 * the License. You may obtain a copy of the License at
 *
 *    http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 *
 ******************************************************************************/
package org.yzbdl.lanius.ui.spoon.bottom;

import org.eclipse.swt.graphics.Image;
import org.pentaho.di.ui.core.gui.LaniusGuiResource;

/**
 * <pre>
 * 
 * 其他任何UI部件与StateBarButton建立监听关系，实现：
 * 1, UI部件通知指定的StateBarButton显示与隐藏
 * 2, StateBarButton通知UI部件做出相应的动作
 * 3, UI部件与StateBarButton通过名称进行关联
 * 
 * </pre>
 * 
 * @author hs@yzbdl.ac.cn
 *
 */
public interface StateButtonItemAdapter {

    public String getStateBarBtnName();

    public String getStateBarBtnImage();

    public void onStateBarBtnClick();

    default Image getImage() {
        return LaniusGuiResource.getInstance().getCpImage(getStateBarBtnImage(), 14, 14);
    }

}
